import { $http } from "@escook/request-miniprogram";

// 获取首页轮播图数据
export function getSwiperList(){
  return $http.get('home/swiperdata')
}
// 查看订单支付状态
export function orderStatus(params){
  return $http.post('my/orders/chkOrder',params)
}
// 创建订单
export function creatOrder(params){
  return $http.post('my/orders/create',params)
}
// 导航
export function navgation(){
  return  $http.get('home/catitems')
}
// 获取用户 token
export function getToken(params){
  return uni.$http.post('users/wxlogin',params)
}
// 获取支付参数
export function getPay(params){
  return $http.post('my/orders/req_unifiedorder',params)
}
// 查阅历史订单
export function getHistoryOrder(params){
  return $http.get('my/orders/all',params)
}
// 楼层
export function getFloorList(){
  return $http.get('home/floordata')
}
//商品分类
export function getShopCateList(){
  return $http.get('categories')
}
//商品列表搜索
export function getShopSearchList(params){
  return $http.get('goods/search',params)
}
//商品搜索
export function shopSearchList(params){
  return $http.get('goods/qsearch',{query:params})
}
// 商品详情
export function getShopDetail(params){
  return $http.get('goods/detail',{goods_id:params})
}

